<?php defined('SYSPATH') or die('No direct script access.') ?>

<div class="row">
    <div class="col-lg-6 col-md-6"><h2>Список тематик</h2></div>
    <div class="col-lg-6 col-md-6"><h2>Новые тематики</h2></div>
</div>
<div class="row">
<?php echo Form::open($controller.'/'.$action.'/short', array('id'=>'subjects_form','class'=>'form-inline','role'=>'form')) ?>
    <ul id="sortable1" class="connectedSortable col-lg-6">
<?php
foreach($subjects as &$row)
{
?>
        <li class="ui-state-default">
            <div class="row">
                <div class="col-lg-1">
                    <span class="glyphicon glyphicon-move"></span>
                </div>
                <div class="col-lg-11">
                    <?php echo Form::input('subjects[]', $row['subjectstext'], array('class'=>'form-control','placeholder'=>'тематика')) ?>
                </div>
            </div>
        </li>
<?php
}
?>
    </ul>

    <ul id="sortable3" class="connectedSortable col-lg-6">

    </ul>

    <div class="row">
        <div class="col-lg-offset-4 col-lg-4">
            <button id="subjects_add" type="button" class="btn btn-default btn-block">Добавить тематику</button>
            <button id="subjects_submit" type="button" class="btn btn-primary btn-block">Сохранить изменения</button>
        </div>

    </div>
</form>

</div>

<div id="subjects_line" class="row hidden">
    <div class="col-lg-1">
        <span class="glyphicon glyphicon-move"></span>
    </div>
    <div class="col-lg-11">
        <?php echo Form::input('subjects[]', '', array('class'=>'form-control','placeholder'=>'тематика')) ?>
    </div>
</div>
